import Vue from 'vue'
import App from './App.vue'
import router from './router'
import './plugins/Element-ui.js'
import './plugins/axios.js'
import './plugins/vue-tree-table.js'
import './plugins/vue-quill-editor.js'
// 引入全局样式表
import './assets/css/global.css'
Vue.config.productionTip = false
// 创建一个全局的时间过滤器
Vue.filter('dateFormat', function (value) {
  const dt = new Date(value)
  const y = dt.getFullYear()
  const m = (dt.getMonth() + 1 + '').padStart(2, 0)
  const d = (dt.getDate() + '').padStart(2, 0)

  const hh = (dt.getHours() + '').padStart(2, 0)
  const mm = (dt.getMinutes() + '').padStart(2, 0)
  const ss = (dt.getSeconds() + '').padStart(2, 0)
  return `${y}-${m}-${d} ${hh}:${mm}:${ss}`
})

new Vue({
  router,
  render: h => h(App)
}).$mount('#app')
